-- GENERATED SPELL FOR [Ambassador Malcin] --


function spell0_12865(pUnit, Event) --@Curse of Blood,n/a--
pUnit:FullCastSpellOnTarget(8282,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_12865', 2000, 1)
end

function spell1_12865(pUnit, Event) --@Shadow Bolt,n/a--
pUnit:FullCastSpellOnTarget(9613,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_12865', 3000, 1)
end

function Sorts_12865(pUnit, Event)
local choix_sorts_12865 = math.random(0, 1)
if choix_sorts_12865 == 0 then
pUnit:RegisterEvent('spell0_12865', 1, 1)
end
if choix_sorts_12865 == 1 then
pUnit:RegisterEvent('spell1_12865', 1, 1)
end
end

function mob12865_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_12865', math.random(1500, 3000), 1)
end

function mob12865_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob12865_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob12865_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(12865, 1, 'mob12865_Action')
RegisterUnitEvent(12865, 2, 'mob12865_Leave')
RegisterUnitEvent(12865, 3, 'mob12865_Kill')
RegisterUnitEvent(12865, 4, 'mob12865_Die')
